<!doctype html>
<html>
<head>
    <include file="public/head"/>
    <title>编辑模型</title>
    <meta name="description" content="编辑模型">
    <meta name="keywords" content="编辑模型">
</head>
<body>
<div class="wrap js-check-wrap">
    <ul class="nav nav-tabs">
        <li><a href="{:cmf_plugin_url('QbtCustomModel://AdminIndex/index')}">模型管理</a></li>
        <li><a href="{:cmf_plugin_url('QbtCustomModel://AdminQbtCustomModel/add')}">添加模型</a></li>
        <li class="active"><a>编辑模型</a></li>
    </ul>
    <form method="post" class="form-horizontal js-ajax-form margin-top-20"
          action="{:cmf_plugin_url('QbtCustomModel://AdminQbtCustomModel/editPost')}">

        <div class="form-group">
            <label class="col-sm-2 control-label"><span class="form-required">*</span>模型名称</label>
            <div class="col-md-6 col-sm-10">
                <input type="text" class="form-control" name="model_name" value="{$model_info.model_name}">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-2 control-label"><span class="form-required">*</span>数据表</label>
            <div class="col-md-6 col-sm-10">
                <input type="text" class="form-control" name="model_tabname" value="{$model_info.model_tabname}">
            </div>
        </div>
		<div class="form-group">
			<label for="input-controller" class="col-sm-2 control-label"><span class="form-required">*</span>控制器</label>
			<div class="col-md-6 col-sm-10">
				<input type="text" class="form-control" id="input-controller" name="model_controller" value="{$model_info.model_controller}">
			</div>
		</div>
        <div class="form-group">
            <label class="col-sm-2 control-label">描述</label>
            <div class="col-md-6 col-sm-10">
                <textarea name="model_description" class="form-control">{$model_info.model_description}</textarea>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-2 control-label">是否启用</label>
            <div class="col-md-6 col-sm-10">
                <select class="form-control valid" name="model_status" id="input-status" aria-invalid="false">
                    <option value="1" <eq name="$model_info.model_status" value="1">selected="selected"</eq>>启用</option>
                    <option value="0" <eq name="$model_info.model_status" value="0">selected="selected"</eq>>禁用</option>
                </select>
            </div>
        </div>

        <div class="col-sm-offset-2 col-sm-10">
			<input type="hidden" class="form-control" name="model_id" value="{$model_info.model_id}">
            <button type="submit" class="btn btn-primary js-ajax-submit">{:lang("SAVE")}</button>
        </div>
    </form>
</div>
<include file="public/scripts"/>
</body>
</html>